{extend name="public:_base" /}

{block name="js"}
<link rel="stylesheet" type="text/css"
    href="__STATIC__/admin/hui/lib/ueditor/1.4.3/third-party/codemirror/codemirror.css">
<script type="text/javascript"
    src="__STATIC__/admin/hui/lib/ueditor/1.4.3/third-party/codemirror/codemirror.js"></script>
<script type="text/javascript">
    var editor = CodeMirror.fromTextArea(document.getElementById('content'), {
        lineNumbers: true,
        lineWrapping: true,
        mode: 'text/html'
    });

</script>
{include file="public/_validform"}
<!--验证-->
<script type="text/javascript" src="__STATIC__/admin/js/tempname.js"></script>
{/block}
{block name="main"}
<div class="page-container">
        <div class="Huialert Huialert-info">
                <i class="Hui-iconfont">&#xe6a6;</i>
                <h4 title="提示相关设置操作时应注意的要点">操作提示</h4>
                <ul>
                    <li>文件名称:只允许以下类型 {$editExt}</li>
                    <li>文件代码: "{" "}"括号内为系统调用函数</li>
                    <li>内部标签格式如下：<br>
                        1.{Dl:list db="product" field="a.*" lang="$data['lang']" order="a.id ASC" limit="20" status="1"}<br>
                        2.{Dl:mlist db="articlemass" field="a.id,a.username,a.center,a.create_time,u.image" lang="$data['lang']" aid="$data['id']" order="a.create_time desc" limit="5" status="1"}<br>
                        3.{Dl:model db="online" field="*" lang="$lang" id="vo"}<br>
                        4.{Dl:model db="carousel" like="type" value="$navid" model="$browsertype"}<br>
                    </li>
                </ul>
            </div>
    <div class="mDiv">
        <div class="ftitle">
            <h3 title="{$Request.param.name??''}">{$Request.param.name??''}</h3>
        </div>
    </div>
    <form action="{:url('setview/save')}" method="post" id="form">

        <div class="row cl" style="display:none">
            <div class=" col-xs-2 col-sm-2">
                工作目录
            </div>
            <div class="formControls col-xs-10 col-sm-10">
                <input name="dir" value="{$Request.param.dir??''}" type="text" class="input-text"
                    style="width: 250px;" />
                <h1 class="btn radius btn-primary radius" data-toggle="tooltip" data-placement="right"
                    title="空白表示根目录，不允许用 “..” 形式的路径">提示</h1>
            </div>
        </div>
        <div class="row cl">
            <div class=" col-xs-2 col-sm-2">
                文件名称
            </div>
            <div class="formControls col-xs-10 col-sm-10">
                <input name="name" value="{$Request.param.name??''}" type="text" class="input-text"
                    style="width: 250px;" />
                <h1 class="btn radius btn-primary radius" data-toggle="tooltip" data-placement="right"
                    title="不允许用 “..” 形式的路径">提示</h1>

            </div>
        </div>
        <div class="row cl">

            <div class=" col-xs-2 col-sm-2">
                文件代码
            </div>
            <div class="formControls col-xs-10 col-sm-10">
                <H2 title="{$Request.param.dirfile??''}">{$Request.param.dirfile??''}</H2>
                <textarea name="filevalue" id='content' class="textarea"
                    style='width:99%;height:650px;background:#ffffff;'>{$value|default=''|htmlentities ?? ''}</textarea>
                <div class="mt-20 text-c">


                    <input name="type" value="{$Request.param.type??''}" type="hidden" class="input-text" />

                    <input class="btn radius btn-primary radius" type="submit" value="确定" />

                </div>
            </div>
        </div>
    </form>

</div>
</div>
{/block}